package com.bjsxt.mapper;

import com.bjsxt.pojo.Role;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;

public interface RoleMapper {
    //查询角色实现
    @Select("select * from t_role")
    List<Role>  selectAll();
    //添加角色实现
    Integer insert(Role role);

    //修改角色实现
    @Update("update t_role set rname=#{rname},rdesc=#{rdesc} where rid=#{rid}")
    Integer  update(Role role);
    //角色删除
    @Delete("delete  from t_role where rid=#{param1}")
    Integer delete(Integer rid);


}
